<?php
/**
 * Description of getvars
 *
 * @author adrian
 */
class Core_Data_Getvars {
    
    /**
     * constructor
     */
    public function __construct() {
        
    }
    
    /**
     * return getVars array
     * 
     * @param string $request
     * @return array $getVars
     */
    public function initializeGetArray($request){
        //parse the page request and other GET variables
        $parsed = explode('&' , $request);

        //the rest of the array are get statements, parse them out.
        $getVars = array();
        foreach ($parsed as $argument){
            //split GET vars along '=' symbol to separate variable, values
            list($variable , $value) = explode('=' , $argument);
            $getVars[$variable] = $value;
        }
        
        return $getVars;
        
    }
}

?>
